home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 869 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.4 KB  |  37 lines

  1. Newsgroups: comp.lang.c
  2. Path: peer-news.britain.eu.net!psinntp!psinntp!psinntp!psinntp!voder!nsc!rustler!toml
  3. From: toml@rustler.nsc.com (Thomas Likens)
  4. Subject: Re: C vs C++ urgently needed Please
  5. Message-ID: <DKxHL5.Eru@nsc.nsc.com>
  6. Sender: news@nsc.nsc.com (netnews maintenance)
  7. Nntp-Posting-Host: rustler.nsc.com
  8. Reply-To: toml@rustler.nsc.com (Thomas Likens)
  9. Organization: National Semiconductor, Santa Clara
  10. References: <819936532.7746@shuh.demon.co.uk> <DKC41u.MGI@news.cis.umn.edu> <820144728snz@intellic.demon.co.uk> <4crp9s$ntb@homesick.cs.unlv.edu> <ALUN.CHAMPION.96Jan9112246@g7240065.bridge.bst.bls.com>
  11. Date: Tue, 9 Jan 1996 19:17:29 GMT
  12.  
  13. In article <ALUN.CHAMPION.96Jan9112246@g7240065.bridge.bst.bls.com>, Alun.Champion@bridge.bst.bls.com (Alun Champion) writes:
  14. |> In article <4crp9s$ntb@homesick.cs.unlv.edu> wiseman@unlv.edu (Christopher A Weiss) writes:
  15. |> 
  16. |> : If you want an interesting wuestion though, try to figure out why they
  17. |> : called it C++ when (by convention) it should have been called ++C.
  18. |> 
  19. |> By which convention should it be ++C ?
  20. |> Most early books (see Kernighan & Ritchie) use the postfix increment operator
  21. |> if the value of the increment wasn't necessary ie.
  22. |> 
  23. |>   for (i = 0; i < someValue; i++) {
  24. |>     ...                      ^^^
  25. |>   }
  26. |> 
  27. |> So by that convention it should be C++ - which it is ;')
  28. |> 
  29. |> Regards
  30. |> 
  31. |>    -A.
  32.  
  33. By the convention that C was updated (incremented) and then used, so
  34. it should be ++C.
  35.  
  36. --Tom
  37.